package com.hua.yuan.manager.user.business.impl;

import android.support.annotation.NonNull;

import com.hua.yuan.manager.user.business.IUserBusiness;
import com.hua.yuan.manager.user.business.callback.IUserCallback;
import com.hua.yuan.manager.user.business.dao.impl.ForgetPwdDaoImpl;
import com.hua.yuan.manager.user.business.dao.impl.RegisterDaoImpl;
import com.hua.yuan.manager.user.business.dao.impl.UpdateInfoDaoImpl;
import com.hua.yuan.manager.user.business.dao.impl.UpdatePwdDaoImpl;
import com.hua.yuan.provider.user.IUserProvider;

import java.util.Map;

/**
 * @Author: richsjeson.
 * @Description: TODO() 用户管理接口
 * @Date:Created in 2019/1/1 1:34 PM.
 * @Modified By:
 */
public class UserBusinessImpl implements IUserBusiness {

    @Override
    public void updateUserInfo(@NonNull final Map pMap,@NonNull final IUserProvider pProvider, final IUserCallback pCallback) {
         new UpdateInfoDaoImpl().update(pMap,pCallback,pProvider);
    }

    @Override
    public void updatePwd(@NonNull final IUserProvider pProvider, @NonNull final String pRepasswd, final IUserCallback pCallback) {

        new UpdatePwdDaoImpl().updatePwd(pProvider,pRepasswd,pCallback);
    }

    @Override
    public void registerUser(@NonNull final Map pMap, @NonNull final IUserProvider pProvider, final IUserCallback pCallback) {

        new RegisterDaoImpl().registerUser(pMap,pProvider,pCallback);
    }

    @Override
    public void updateHeaderUrl(@NonNull final String pUrl, @NonNull final String pSmsCode, @NonNull final IUserProvider pProvider, final IUserCallback pCallback) {

    }

    @Override
    public void getUserInfo(final IUserCallback pCallback) {

    }

    @Override
    public void forgetPasswd(@NonNull final Map pMap, @NonNull final IUserProvider pProvider, final IUserCallback pCallback) {

        new ForgetPwdDaoImpl().forgetPasswd(pMap,pProvider,pCallback);
    }
}
